// <copyright>
// Project: sofort.NET
// Date:  2014 - 02 - 04
// Copyright: Karl Haak 2014
// </copyright>
// <author>Karl Haak (www.karlhaak.de)</author>
namespace pay.sofort.Models.Mapping
{
    public class PaySofortMultipayMap : PaySofortBaseMap<PaySofortMultipay>
    {
        public PaySofortMultipayMap()
        {
            // Primary Key
            HasKey(t => t.PaySofortMultipayGuid);

            // Properties
            Property(t => t.interface_version)
                .HasMaxLength(250);

            Property(t => t.language_code)
                .HasMaxLength(2);

            Property(t => t.email_customer)
                .HasMaxLength(250);

            Property(t => t.phone_customer)
                .HasMaxLength(250);

            Property(t => t.user_variable_1)
                .HasMaxLength(250);

            Property(t => t.user_variable_2)
                .HasMaxLength(250);

            Property(t => t.user_variable_3)
                .HasMaxLength(250);

            Property(t => t.sender_holder)
                .HasMaxLength(30);

            Property(t => t.sender_account_number)
                .HasMaxLength(30);

            Property(t => t.sender_bank_code)
                .HasMaxLength(30);

            Property(t => t.sender_country_code)
                .HasMaxLength(2);

            Property(t => t.sender_iban)
                .HasMaxLength(34);

            Property(t => t.sender_bic)
                .HasMaxLength(11);

            Property(t => t.currency_code)
                .IsRequired()
                .HasMaxLength(3);

            Property(t => t.reason_1)
                .HasMaxLength(30);

            Property(t => t.reason_2)
                .HasMaxLength(30);

            Property(t => t.reason_3)
                .HasMaxLength(30);

            Property(t => t.success_url)
                .HasMaxLength(250);

            Property(t => t.abort_url)
                .HasMaxLength(250);

            Property(t => t.timeout_url)
                .HasMaxLength(250);

            Property(t => t.notification_url_1)
                .HasMaxLength(250);

            Property(t => t.notification_url_1_notify_on)
                .HasMaxLength(250);

            Property(t => t.notification_url_2)
                .HasMaxLength(250);

            Property(t => t.notification_url_2_notify_on)
                .HasMaxLength(250);

            Property(t => t.notification_url_3)
                .HasMaxLength(250);

            Property(t => t.notification_url_3_notify_on)
                .HasMaxLength(250);

            Property(t => t.notification_url_4)
                .HasMaxLength(250);

            Property(t => t.notification_url_4_notify_on)
                .HasMaxLength(250);

            Property(t => t.notification_email_1)
                .HasMaxLength(250);

            Property(t => t.notification_email_1_notify_on)
                .HasMaxLength(250);

            Property(t => t.notification_email_2)
                .HasMaxLength(250);

            Property(t => t.notification_email_2_notify_on)
                .HasMaxLength(250);


            // Table & Column Mappings
            ToTable("PaySofortMultipay");
            Property(t => t.PaySofortMultipayGuid).HasColumnName("PaySofortMultipayGuid");
            Property(t => t.project_id).HasColumnName("project_id");
            Property(t => t.interface_version).HasColumnName("interface_version");
            Property(t => t.language_code).HasColumnName("language_code");
            Property(t => t.timeout).HasColumnName("timeout");
            Property(t => t.email_customer).HasColumnName("email_customer");
            Property(t => t.phone_customer).HasColumnName("phone_customer");
            Property(t => t.user_variable_1).HasColumnName("user_variable_1");
            Property(t => t.user_variable_2).HasColumnName("user_variable_2");
            Property(t => t.user_variable_3).HasColumnName("user_variable_3");
            Property(t => t.sender_holder).HasColumnName("sender_holder");
            Property(t => t.sender_account_number).HasColumnName("sender_account_number");
            Property(t => t.sender_bank_code).HasColumnName("sender_bank_code");
            Property(t => t.sender_country_code).HasColumnName("sender_country_code");
            Property(t => t.sender_iban).HasColumnName("sender_iban");
            Property(t => t.sender_bic).HasColumnName("sender_bic");
            Property(t => t.amount).HasColumnName("amount");
            Property(t => t.currency_code).HasColumnName("currency_code");
            Property(t => t.reason_1).HasColumnName("reason_1");
            Property(t => t.reason_2).HasColumnName("reason_2");
            Property(t => t.reason_3).HasColumnName("reason_3");
            Property(t => t.success_url).HasColumnName("success_url");
            Property(t => t.success_link_redirect).HasColumnName("success_link_redirect");
            Property(t => t.abort_url).HasColumnName("abort_url");
            Property(t => t.timeout_url).HasColumnName("timeout_url");
            Property(t => t.notification_url_1).HasColumnName("notification_url_1");
            Property(t => t.notification_url_1_notify_on).HasColumnName("notification_url_1_notify_on");
            Property(t => t.notification_url_2).HasColumnName("notification_url_2");
            Property(t => t.notification_url_2_notify_on).HasColumnName("notification_url_2_notify_on");
            Property(t => t.notification_url_3).HasColumnName("notification_url_3");
            Property(t => t.notification_url_3_notify_on).HasColumnName("notification_url_3_notify_on");
            Property(t => t.notification_url_4).HasColumnName("notification_url_4");
            Property(t => t.notification_url_4_notify_on).HasColumnName("notification_url_4_notify_on");
            Property(t => t.notification_email_1).HasColumnName("notification_email_1");
            Property(t => t.notification_email_1_notify_on).HasColumnName("notification_email_1_notify_on");
            Property(t => t.notification_email_2).HasColumnName("notification_email_2");
            Property(t => t.notification_email_2_notify_on).HasColumnName("notification_email_2_notify_on");
            Property(t => t.su_customer_protection).HasColumnName("su_customer_protection");
        }
    }
}